<template>
  <van-sidebar v-model="active">
    <van-sidebar-item title="标签名称" dot />
    <van-sidebar-item title="标签名称" badge="5" />
    <van-sidebar-item title="标签名称" badge="20" />
  </van-sidebar>

  <!-- 结算模块 -->
  <div class="bottom">
    <div class="left">
      <van-icon name="shopping-cart-o" />
    </div>
    <div class="right">
      <div class="price-box">
        <p class="price">￥00.00</p>
        <p class="distribution">配送费￥5</p>
      </div>
      <van-button color="#333" disabled v-if="price < 20">￥20起送</van-button>
      <van-button type="primary" v-else>结算</van-button>
    </div>
  </div>
</template>

<script setup>
import { ref } from 'vue'
const active = ref(0)

const price = ref(150)
</script>

<style scoped lang="less">
:deep(.van-sidebar-item .van-sidebar-item__text) {
  font-size: 28px !important;
  color: #333;
  margin: 0;
}

.bottom {
  display: flex;
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 90px;
  background-color: #fff;
  border-top: 1px solid #ccc;
  .left {
    position: relative;
    left: 20px;
    bottom: 40px;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background-color: #fff;
    line-height: 90px;
    text-align: center;
  }
  :deep(.van-icon-shopping-cart-o) {
    color: #0a92e7;
    margin: 0;
    font-size: 60px !important;
  }
  .right {
    display: flex;
    justify-content: space-between;
    .price-box {
      margin: 6px 325px 10px 30px;
      .price {
        color: #ff692d;
        font-size: 32px;
        font-weight: bold;
      }
      .distribution {
        color: #333;
        font-size: 24px;
      }
    }
    :deep(.van-button--primary) {
      width: 180px;
    }
  }
}
</style>
